/*
 * @Author: 吴世扬 18368095041@163.com
 * @Date: 2025-02-13 11:28:16
 * @LastEditors: 吴世扬 18368095041@163.com
 * @LastEditTime: 2025-02-13 16:29:41
 * @FilePath: /vue3-admin-server/src/common/dto/login.ts
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import { IsNotEmpty, IsString } from 'class-validator';

export class LoginByPasswordDTO {
    @IsNotEmpty({ message: '用户名不能为空' })
    @IsString({ message: '用户名必须为字符串' })
    username: string;

    @IsNotEmpty({ message: '密码不能为空' })
    @IsString({ message: '密码必须为字符串' })
    password: string;

    @IsNotEmpty({ message: '验证码不能为空' })
    @IsString({ message: '验证码必须为字符串' })
    captcha: string;
}
